package cn.itcast.bos.dao.base;

import java.io.Serializable;
import java.util.List;

import org.hibernate.criterion.DetachedCriteria;

import cn.itcast.bos.domain.pagebean.PageBean;

public interface IBaseDao<T> {
	public void save(T entity);
	
	public void delete(T entity);
	
	public void update(T entity);
	
	public T findById(Serializable id);
	
	public List<T> findAll();
	
	//根据查询对象查询
	public List<T> findByCriteria(DetachedCriteria criteria);
	
	//根据命名语句查询
	public List<T> findByNameQuery(String queryName,Object...args);
	
	//执行增删改操作的 命名语句
	public void executeNameQuery(String queryName,Object...args);
	
	//通用分页查询
	public void pageQueryList(PageBean pageBean);
	/*///////
*/
	}
